<div class="reports">
  <div class="report_header">
    <div class="report_header_content">
      <%= form_tag "/reports/data/#{@report.report_name}", :method => :get, :remote => true, :id => "reports_form" do %>
          <div class="report_date">
            <div class="control_name">
              <p><%= t('views.reports.date_range') %></p>
            </div>
            <input name="criteria[from_date]" type="text" id="from_date" value="<%= 1.month.ago.to_date.strftime(get_date_format) %>"/>

            <p>to</p>
            <input name="criteria[to_date]" type="text" id="to_date" value="<%= Date.today.strftime(get_date_format) %>"/>
          </div>
          <div class="report_clients">
            <div class="control_name">
              <p><%= t('views.clients.client') %></p>
            </div>
            <div class="client_select">
              <%#= collection_select "criteria", "item_id", [Item.new({:id => 0, :item_name => "All"})] + Item.all, :id, :item_name, {:prompt => "All"}, {:class => "item chzn-select"} %>
              <%= collection_select "criteria", "client_id", [Client.new({:id => 0, :organization_name => t('views.common.all')})] + get_report_clients, :id, :organization_name, {:prompt => t('views.common.all')}, {:class => "client chzn-select"} %>
            </div>
            <div class="control_name">
              <p><%= t('views.common.type') %></p>
            </div>
            <div class="client_select"><%= select_tag "criteria[payment_method]", options_for_select(PAYMENT_METHODS.map { |p| [p, p] }), {:prompt => t('views.common.all'), :class => "payment-method chzn-select"} %></div>
          </div>
          <div class="report_update">
            <%= submit_tag t('views.common.go'), :class => "report_update" %>
          </div>
      <% end %>
    </div>
  </div>
  <!-- report_header -->
</div><!--reports-->